{% extends "base.html" %}
{% load i18n %}
{% load markup %}

{% block title %}{% trans "Stories" %} - {{ section }}{% endblock %}

{% block extrahead %}
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" 
      href="http://{{ site.domain }}/rss/stories/{{ section.slug }}" />
<link rel="alternate" type="application/atom+xml" title="Atom 1.0" 
      href="http://{{ site.domain }}/atom/stories/{{ section.slug }}" />
{% endblock %}

{% block content %}
<h2>{% trans "Stories" %}</h2>
<h3>{{ section }}</h3>
{% for story in latest %}
<div>
  <h3><a href="{{ story.get_absolute_url }}">{{ story.headline }}</a></h3>
  <p class="date">{{ story.pub_date|date:"l, F jS, Y" }}</p>
  <p class="byline">{% trans "By" %}{% ifnotequal story.user.get_full_name "" %} {{ story.user.get_full_name }}{% else %} {{ story.user.username }}{% endifnotequal %}</p>
  {{ story.body|markdown|truncatewords:40 }}
 </div>
{% endfor %}
{% endblock %}
